package cn.hk.service;

import cn.HK.po.User;
import cn.HK.utils.MD5Util;
import cn.hk.mapper.RegistMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
public class RegistService {
    @Autowired(required = false)
    private RegistMapper registMapper;
    public void doRegister(User user) {
        //对密码进行加密
        user.setuPassword(MD5Util.md5(user.getuPassword()));
        System.out.println(user);
        registMapper.insertRegist(user);
    }
}
